import * as types from "./types";
//提交mutation，异步操作
//组件中使用dispatch来发出 Actions
var actions={
    show_loading ({commit},item) {
        return new Promise((resolve,reject) =>{
            commit(types.SHOW_LOADING)
            resolve();
        });
    },hide_loading ({commit},item){
        return new Promise((resolve,reject)=>{
            commit(types.HIDE_LOADING)
            resolve();
        });
    }
}
export default actions;